/*TCSS 360 ConferenceGuru
 * 
 * Author: Tyler Simrell
 * Co-Author: Lawrence Grass
 */
package gui;

import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Dimension;
import java.awt.Font;
import java.awt.ScrollPane;

import javax.swing.JButton;
import javax.swing.JLabel;
import javax.swing.JPanel;

import model.Author;
import model.Conference;


@SuppressWarnings("serial")
public class AuthorViewPanel extends JPanel
{	
	final int SIDEBAR_WIDTH = 135;	
	final int SIDEBAR_HEIGHT = 640;
	final int TITLE_WIDTH = 800;
	final int TITLE_HEIGHT = 200;
	Author my_role;
	Conference my_conference;
	JButton authorMenuButton;
	JButton getReviewsButton = new JButton();
	JButton editSubmissionButton = new JButton();
	ScrollPane replaceableView;
	JPanel outer_view_panel;
	
	public AuthorViewPanel(Author the_author, Conference the_conference)
	{
		super(new BorderLayout());
		this.setOpaque(false);
		my_role = the_author;
		my_conference = the_conference;
		titlePaneSetup();
		setUpPanel();
		
	}
	
	//This setUpPanel method, being that the Author Role GUI has been simplified so heavily
	//is rather short. It mostly creates the panel and revalidates it.
	private void setUpPanel() 
	{
		AuthorPanelSeeReviews mainPanel = new AuthorPanelSeeReviews(my_role, my_conference);
		add(mainPanel);
		super.revalidate();
	}

	private void titlePaneSetup() 
	{
		JPanel title_pane = new JPanel();
		title_pane.setBackground(BaseViewFrame.BACKGROUND_COLOR);
		title_pane.setPreferredSize(new Dimension(TITLE_WIDTH, TITLE_HEIGHT/2));
		JLabel welcome = new JLabel("Welcome to your workspace, " + my_role.getName() + "!");
		welcome.setFont(new Font("serif", Font.ROMAN_BASELINE, 30));
		welcome.setForeground(Color.BLACK);
		title_pane.add(welcome);
		add(title_pane, BorderLayout.NORTH);
	}
}
